package com.warm.calc.demo.controller;

import com.warm.calc.demo.service.CalcService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

@RestController
@RequestMapping("/calc")
public class CalcController {

    @Resource
    private CalcService calcService;

    @PostMapping("/export/data")
    public Boolean exportData(@RequestBody Object data){
        return calcService.exportData(data);
    }
}
